<template>
    <div class="itemWrap" @click="fn">
        <span v-show="bol">
            <slot name="activeImg"></slot>
        </span>
        <span v-show="!bol">
            <slot name="normalImg"></slot>
        </span>
    </div>
</template>
<script>
export default {
    name: "item",
    props: ["mark","sel"],
    methods: {
        fn(){
            this.$emit("change",this.mark);
        }
    },
    computed: {
        bol:function(){
            if(this.mark==this.sel){
                return true;
            }else{
                return false;
            }
        }
    }
}
</script>